<h1>Listing Tag Groups</h1>

<table class="list">
  <tr>
    <th>Name</th>
	<th>Created_at</th>
	<th>Created_by</th>
	<th>Show</th>
	<th>Edit</th>
	<th>Delete</th>
  </tr>
  
<% for tag_group in @tag_groups %>
  <tr>
    <td><%=h tag_group.name %></td>
	<td><%=h tag_group.created_at.strftime('%d/%m/%Y') %></td>
	<td><%=h tag_group.created_by %></td>
    <td><%= link_to 'Show', :action => 'show', :id => tag_group %></td>
    <td><%= link_to 'Edit', :action => 'edit', :id => tag_group %></td>
    <td><%= link_to 'Delete', { :action => 'destroy', :id => tag_group }, :confirm => 'Are you sure?', :method => :post %></td>
  </tr>
<% end %>
</table>

<%= link_to 'Previous page', { :page => @tag_group_pages.current.previous } if @tag_group_pages.current.previous %>
<%= link_to 'Next page', { :page => @tag_group_pages.current.next } if @tag_group_pages.current.next %> 

<br />

<%= link_to 'New Tag Group', :action => 'new' %>
